<?php

namespace app\modules\admin\models;

use Yii;

/**
 * This is the model class for table "dictionary_attribute".
 *
 * @property int $id 主键id
 * @property string $field_value 字段值
 * @property string $attribute_name 属性名称
 * @property string $attribute_value 属性值
 * @property int $deleted 是否删除
 * @property string $created 创建时间
 * @property string $modified 修改时间
 */
class DictionaryAttribute extends BaseModel
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 'dictionary_attribute';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['field_value', 'attribute_name', 'attribute_value'], 'required'],
            [['deleted'], 'integer'],
            [['created', 'modified'], 'safe'],
            [['field_value', 'attribute_name', 'attribute_value'], 'string', 'max' => 50],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'id' => Yii::t('app', '主键id'),
            'field_value' => Yii::t('app', '字段值'),
            'attribute_name' => Yii::t('app', '属性名称'),
            'attribute_value' => Yii::t('app', '属性值'),
            'deleted' => Yii::t('app', '是否删除'),
            'created' => Yii::t('app', '创建时间'),
            'modified' => Yii::t('app', '修改时间'),
        ];
    }
}
